Skip to content

Fix #14803: ValueType::BOOL set for && in rvalue reference declaration#8606

Open
ludviggunne wants to merge 2 commits into
cppcheck-opensource:mainfrom
ludviggunne:14803
Open

Fix #14803: ValueType::BOOL set for && in rvalue reference declaration#8606
ludviggunne wants to merge 2 commits into
cppcheck-opensource:mainfrom
ludviggunne:14803

Conversation

@ludviggunne
Copy link
Copy Markdown
Collaborator

No description provided.

Comment thread lib/symboldatabase.cpp
setValueType(tok, ValueType(sign, type, 0U));
}
} else if (tok->isComparisonOp() || tok->tokType() == Token::eLogicalOp) {
} else if ((tok->isComparisonOp() || tok->tokType() == Token::eLogicalOp) && tok->astOperand1()) {
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I suggest we call tok->isBinaryOp() instead to make it more explicit

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants